package custom.captcha.network;


import custom.captcha.model.CaptchaCheckIt;
import custom.captcha.model.CaptchaGetIt;
import custom.captcha.model.WordCaptchaGetIt;
import io.reactivex.Observable;
import okhttp3.RequestBody;
import retrofit2.http.Body;
import retrofit2.http.POST;

import static custom.base.http.data.HttpConstants.BASE;

/**
 * Date:2020/5/18
 * author:wuyan
 */
public interface ServerApi {

    final static String BaseUrl = BASE + "admin-api/";
//    final static String BaseUrl = "http://10.108.12.11:8080/";

    //获取验证码
    @POST("system/captcha/get")
    Observable<CaptchaBaseResponse<CaptchaGetIt>> getAsync(@Body RequestBody body);

    //获取文字的验证码
    @POST("system/captcha/get")
    Observable<CaptchaBaseResponse<WordCaptchaGetIt>> getWordCaptchaAsync(@Body RequestBody body);

    //核对验证码
    @POST("system/captcha/check")
    Observable<CaptchaBaseResponse<CaptchaCheckIt>> checkAsync(@Body RequestBody body);
}
